import request from '@/utils/request';

export async function getTypeList(params) {
  return request(`/mgrApi/plcyDataDict/entrySerTypeList`, {
    method: 'POST',
    body: params,
  });
}
export async function getAreaList(params) {
  return request(`/mgrApi/suppBusiScope/getAreaList`, {
    method: 'POST',
    body: params,
  });
}
export async function getList(params) {
  return request(`/mgrApi/serMatPkg/pagePkgList`, {
    method: 'POST',
    body: params,
  });
}

export async function delList(params) {
  return request(`/mgrApi/serMatPkg/delete`, {
    method: 'POST',
    body: params,
  });
}

export async function getMatListPage(params) {
  return request(`/mgrApi/mdm/baseService/queryMatInfoPageList`, {
    method: 'POST',
    body: params,
  });
}

export async function getMatList(params) {
  return request(`/mgrApi/mdm/baseService/queryMatInfoList`, {
    method: 'POST',
    body: params,
  });
}

export async function getJudgeDict(params) {
  return request(`/mgrApi/mdm/nmDict/getDictItemList`, {
    method: 'POST',
    body: params,
  });
}
export async function getMatDetail(params) {
  return request(`/mgrApi/serMatPkg/getMatPkgById`, {
    method: 'POST',
    body: params,
  });
}
export async function getDict(params) {
  return request(`/csApi/mdm/nmDict/queryDictItemsByCodes`, {
    method: 'POST',
    body: params,
  });
}
export async function save(params) {
  return request(`/mgrApi/serMatPkg/insert`, {
    method: 'POST',
    body: params,
  });
}
export async function update(params) {
  return request(`/mgrApi/serMatPkg/update`, {
    method: 'POST',
    body: params,
  });
}
